package login;

import org.apache.hadoop.io.LongWritable;
import org.apache.hadoop.mapreduce.Reducer;

import java.io.IOException;

public class loginReducer extends Reducer<MemberDate, LongWritable,MemberDate,LongWritable> {
    @Override
    protected void reduce(MemberDate key, Iterable<LongWritable> values, Reducer<MemberDate, LongWritable, MemberDate, LongWritable>.Context context) throws IOException, InterruptedException {
        //
        long count=0;
        for (LongWritable v : values) {
            count=count+v.get();

        }
        context.write(key,new LongWritable(count));
    }
}
